<?php
	class chudebs
	{
		// Các trường
		public $MaChuDe = "";
		public $TenChuDe = "";
        
        //Phân trang
        public $SoChuDe = 6;
        public $P = 1;
		
		// Các phương thức
		public function Add()
		{
			$db = new chudedb();
			return $db->Add($this->MaChuDe, $this->TenChuDe);
		}
		
		public function IssetTopics()
		{
			$db = new chudedb();
			return $db->IssetTopics($this->MaChuDe, $this->TenChuDe);
		}
		
		public function GetListTopics()
		{
			$db = new chudedb();
			return $db->GetListTopics($this->MaChuDe, $this->TenChuDe);
		}
		
		public function Update()
		{
			$db = new chudedb();
			return $db->Update($this->MaChuDe, $this->TenChuDe);
		}
		
		public function Delete()
		{
			$db = new chudedb();
			return $db->Delete($this->MaChuDe);
		}
        
        public function TotalPage()
		{
			$db = new chudedb();
			return $db->TotalPage($this->SoChuDe);
		}
        
        public function Paging()
		{
			$db = new chudedb();
			return $db->Paging($this->SoChuDe, $this->P);
		}
	}
?>